<?php
/**
 * Created by PhpStorm.
 * User: zyark
 * Date: 2017/8/31
 * Time: 20:56
 */

namespace Home\Logic;


class PrizeLogic
{
    /**
     * 条件查询
     * @param $map 查询条件
     * @return mixed
     */
    public function getByConditionPage($map){
        $list = D('Prize')
            ->where($map)->order('id desc')
            ->field('id,title,image_url,type,number')
            ->order('sort_num asc')//排序字段升序
            ->select();
        $data['list'] = $list;
        return $data;
    }

}